Optimal. Leaf size=232 \[ \frac {2 C \sinh ^{-1}\left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}}{a^{5/2} d}+\frac {(5 A-43 C) \tanh ^{-1}\left (\frac {\sqrt {a} \sqrt {\sec (c+d x)} \sin (c+d x)}{\sqrt {2} \sqrt {a+a \sec (c+d x)}}\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}}{16 \sqrt {2} a^{5/2} d}-\frac {(A+C) \sin (c+d x)}{4 d \cos ^{\frac {5}{2}}(c+d x) (a+a \sec (c+d x))^{5/2}}+\frac {(5 A-11 C) \sin (c+d x)}{16 a d \cos ^{\frac {3}{2}}(c+d x) (a+a \sec (c+d x))^{3/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.48, antiderivative size = 232, normalized size of antiderivative = 1.00, number of steps
used = 8, number of rules used = 8, integrand size = 37, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.216, Rules used = {4350, 4170,
4104, 4108, 3893, 212, 3886, 221} \begin {gather*} \frac {(5 A-43 C) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)} \tanh ^{-1}\left (\frac {\sqrt {a} \sin (c+d x) \sqrt {\sec (c+d x)}}{\sqrt {2} \sqrt {a \sec (c+d x)+a}}\right )}{16 \sqrt {2} a^{5/2} d}+\frac {2 C \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)} \sinh ^{-1}\left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {a \sec (c+d x)+a}}\right )}{a^{5/2} d}+\frac {(5 A-11 C) \sin (c+d x)}{16 a d \cos ^{\frac {3}{2}}(c+d x) (a \sec (c+d x)+a)^{3/2}}-\frac {(A+C) \sin (c+d x)}{4 d \cos ^{\frac {5}{2}}(c+d x) (a \sec (c+d x)+a)^{5/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 221
Rule 3886
Rule 3893
Rule 4104
Rule 4108
Rule 4170
Rule 4350
Rubi steps
\begin {align*} \int \frac {A+C \sec ^2(c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+a \sec (c+d x))^{5/2}} \, dx &=\left (\sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {\sec ^{\frac {3}{2}}(c+d x) \left (A+C \sec ^2(c+d x)\right )}{(a+a \sec (c+d x))^{5/2}} \, dx\\ &=-\frac {(A+C) \sin (c+d x)}{4 d \cos ^{\frac {5}{2}}(c+d x) (a+a \sec (c+d x))^{5/2}}-\frac {\left (\sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {\sec ^{\frac {3}{2}}(c+d x) \left (-\frac {1}{2} a (5 A-3 C)-4 a C \sec (c+d x)\right )}{(a+a \sec (c+d x))^{3/2}} \, dx}{4 a^2}\\ &=-\frac {(A+C) \sin (c+d x)}{4 d \cos ^{\frac {5}{2}}(c+d x) (a+a \sec (c+d x))^{5/2}}+\frac {(5 A-11 C) \sin (c+d x)}{16 a d \cos ^{\frac {3}{2}}(c+d x) (a+a \sec (c+d x))^{3/2}}-\frac {\left (\sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {\sqrt {\sec (c+d x)} \left (-\frac {1}{4} a^2 (5 A-11 C)-8 a^2 C \sec (c+d x)\right )}{\sqrt {a+a \sec (c+d x)}} \, dx}{8 a^4}\\ &=-\frac {(A+C) \sin (c+d x)}{4 d \cos ^{\frac {5}{2}}(c+d x) (a+a \sec (c+d x))^{5/2}}+\frac {(5 A-11 C) \sin (c+d x)}{16 a d \cos ^{\frac {3}{2}}(c+d x) (a+a \sec (c+d x))^{3/2}}+\frac {\left ((5 A-43 C) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \frac {\sqrt {\sec (c+d x)}}{\sqrt {a+a \sec (c+d x)}} \, dx}{32 a^2}+\frac {\left (C \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \int \sqrt {\sec (c+d x)} \sqrt {a+a \sec (c+d x)} \, dx}{a^3}\\ &=-\frac {(A+C) \sin (c+d x)}{4 d \cos ^{\frac {5}{2}}(c+d x) (a+a \sec (c+d x))^{5/2}}+\frac {(5 A-11 C) \sin (c+d x)}{16 a d \cos ^{\frac {3}{2}}(c+d x) (a+a \sec (c+d x))^{3/2}}-\frac {\left ((5 A-43 C) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{2 a-x^2} \, dx,x,-\frac {a \sqrt {\sec (c+d x)} \sin (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right )}{16 a^2 d}-\frac {\left (2 C \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {1+\frac {x^2}{a}}} \, dx,x,-\frac {a \tan (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right )}{a^3 d}\\ &=\frac {2 C \sinh ^{-1}\left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}}{a^{5/2} d}+\frac {(5 A-43 C) \tanh ^{-1}\left (\frac {\sqrt {a} \sqrt {\sec (c+d x)} \sin (c+d x)}{\sqrt {2} \sqrt {a+a \sec (c+d x)}}\right ) \sqrt {\cos (c+d x)} \sqrt {\sec (c+d x)}}{16 \sqrt {2} a^{5/2} d}-\frac {(A+C) \sin (c+d x)}{4 d \cos ^{\frac {5}{2}}(c+d x) (a+a \sec (c+d x))^{5/2}}+\frac {(5 A-11 C) \sin (c+d x)}{16 a d \cos ^{\frac {3}{2}}(c+d x) (a+a \sec (c+d x))^{3/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 3.59, size = 144, normalized size = 0.62 \begin {gather*} \frac {2 (5 A-43 C) \tanh ^{-1}\left (\sin \left (\frac {1}{2} (c+d x)\right )\right ) \cos ^3\left (\frac {1}{2} (c+d x)\right )+64 \sqrt {2} C \tanh ^{-1}\left (\sqrt {2} \sin \left (\frac {1}{2} (c+d x)\right )\right ) \cos ^3\left (\frac {1}{2} (c+d x)\right )+(A-15 C+(5 A-11 C) \cos (c+d x)) \tan \left (\frac {1}{2} (c+d x)\right )}{16 a^2 d \sqrt {\cos (c+d x)} (1+\cos (c+d x)) \sqrt {a (1+\sec (c+d x))}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(539\) vs.
\(2(193)=386\).
time = 0.16, size = 540, normalized size = 2.33
method | result | size |
default | \(-\frac {\left (-1+\cos \left (d x +c \right )\right )^{2} \sqrt {\frac {a \left (1+\cos \left (d x +c \right )\right )}{\cos \left (d x +c \right )}}\, \left (-16 C \arctan \left (\frac {\sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \left (1+\cos \left (d x +c \right )+\sin \left (d x +c \right )\right ) \sqrt {2}}{4}\right ) \sqrt {2}\, \sin \left (d x +c \right ) \cos \left (d x +c \right )-16 C \arctan \left (\frac {\sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \left (-1-\cos \left (d x +c \right )+\sin \left (d x +c \right )\right ) \sqrt {2}}{4}\right ) \sqrt {2}\, \sin \left (d x +c \right ) \cos \left (d x +c \right )+5 A \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \left (\cos ^{2}\left (d x +c \right )\right )-5 A \arctan \left (\frac {\sin \left (d x +c \right ) \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}}{2}\right ) \sin \left (d x +c \right ) \cos \left (d x +c \right )-16 C \arctan \left (\frac {\sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \left (1+\cos \left (d x +c \right )+\sin \left (d x +c \right )\right ) \sqrt {2}}{4}\right ) \sqrt {2}\, \sin \left (d x +c \right )-16 C \arctan \left (\frac {\sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \left (-1-\cos \left (d x +c \right )+\sin \left (d x +c \right )\right ) \sqrt {2}}{4}\right ) \sqrt {2}\, \sin \left (d x +c \right )-11 C \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \left (\cos ^{2}\left (d x +c \right )\right )+43 C \arctan \left (\frac {\sin \left (d x +c \right ) \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}}{2}\right ) \sin \left (d x +c \right ) \cos \left (d x +c \right )-4 A \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \cos \left (d x +c \right )-5 A \arctan \left (\frac {\sin \left (d x +c \right ) \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}}{2}\right ) \sin \left (d x +c \right )-4 C \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\, \cos \left (d x +c \right )+43 C \arctan \left (\frac {\sin \left (d x +c \right ) \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}}{2}\right ) \sin \left (d x +c \right )-A \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}+15 C \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}\right ) \left (\sqrt {\cos }\left (d x +c \right )\right )}{16 d \,a^{3} \sin \left (d x +c \right )^{5} \sqrt {-\frac {2}{1+\cos \left (d x +c \right )}}}\) | \(540\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 7863 vs.
\(2 (193) = 386\).
time = 1.35, size = 7863, normalized size = 33.89 \begin {gather*} \text {Too large to display} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.51, size = 716, normalized size = 3.09 \begin {gather*} \left [-\frac {\sqrt {2} {\left ({\left (5 \, A - 43 \, C\right )} \cos \left (d x + c\right )^{3} + 3 \, {\left (5 \, A - 43 \, C\right )} \cos \left (d x + c\right )^{2} + 3 \, {\left (5 \, A - 43 \, C\right )} \cos \left (d x + c\right ) + 5 \, A - 43 \, C\right )} \sqrt {a} \log \left (-\frac {a \cos \left (d x + c\right )^{2} + 2 \, \sqrt {2} \sqrt {a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt {\cos \left (d x + c\right )} \sin \left (d x + c\right ) - 2 \, a \cos \left (d x + c\right ) - 3 \, a}{\cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) + 1}\right ) - 4 \, {\left ({\left (5 \, A - 11 \, C\right )} \cos \left (d x + c\right ) + A - 15 \, C\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt {\cos \left (d x + c\right )} \sin \left (d x + c\right ) - 32 \, {\left (C \cos \left (d x + c\right )^{3} + 3 \, C \cos \left (d x + c\right )^{2} + 3 \, C \cos \left (d x + c\right ) + C\right )} \sqrt {a} \log \left (\frac {a \cos \left (d x + c\right )^{3} - 4 \, \sqrt {a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} {\left (\cos \left (d x + c\right ) - 2\right )} \sqrt {\cos \left (d x + c\right )} \sin \left (d x + c\right ) - 7 \, a \cos \left (d x + c\right )^{2} + 8 \, a}{\cos \left (d x + c\right )^{3} + \cos \left (d x + c\right )^{2}}\right )}{64 \, {\left (a^{3} d \cos \left (d x + c\right )^{3} + 3 \, a^{3} d \cos \left (d x + c\right )^{2} + 3 \, a^{3} d \cos \left (d x + c\right ) + a^{3} d\right )}}, -\frac {\sqrt {2} {\left ({\left (5 \, A - 43 \, C\right )} \cos \left (d x + c\right )^{3} + 3 \, {\left (5 \, A - 43 \, C\right )} \cos \left (d x + c\right )^{2} + 3 \, {\left (5 \, A - 43 \, C\right )} \cos \left (d x + c\right ) + 5 \, A - 43 \, C\right )} \sqrt {-a} \arctan \left (\frac {\sqrt {2} \sqrt {-a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt {\cos \left (d x + c\right )}}{a \sin \left (d x + c\right )}\right ) - 2 \, {\left ({\left (5 \, A - 11 \, C\right )} \cos \left (d x + c\right ) + A - 15 \, C\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt {\cos \left (d x + c\right )} \sin \left (d x + c\right ) - 32 \, {\left (C \cos \left (d x + c\right )^{3} + 3 \, C \cos \left (d x + c\right )^{2} + 3 \, C \cos \left (d x + c\right ) + C\right )} \sqrt {-a} \arctan \left (\frac {2 \, \sqrt {-a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sqrt {\cos \left (d x + c\right )} \sin \left (d x + c\right )}{a \cos \left (d x + c\right )^{2} - a \cos \left (d x + c\right ) - 2 \, a}\right )}{32 \, {\left (a^{3} d \cos \left (d x + c\right )^{3} + 3 \, a^{3} d \cos \left (d x + c\right )^{2} + 3 \, a^{3} d \cos \left (d x + c\right ) + a^{3} d\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {A+\frac {C}{{\cos \left (c+d\,x\right )}^2}}{{\cos \left (c+d\,x\right )}^{3/2}\,{\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right )}^{5/2}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________